package pl.enigmatic.util;

public interface IConverter<X, Y> {

	Y convert(X x);

	IConverter<Double, Float> instanceDoubleFloat = new IConverter<Double, Float>() {

		@Override
		public Float convert(final Double d) {
			return d.floatValue();
		}
	};

	IConverter<Float, Double> instanceFloatDouble = new IConverter<Float, Double>() {

		@Override
		public Double convert(final Float f) {
			return f.doubleValue();
		}
	};
}
